<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <div id="app">
        <div v-if="cond==4">cond</div>
        <div v-if="cond==1">one！</div>
        <div v-if="cond==2">two！</div>
        <div v-if="cond==3">three！</div>
        <div class="btn-group">
            <button @click="one">one</button>
            <button @click="two">two</button>
            <button @click="three">three</button>
        </div>

    </div>
    <!-- <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script> -->
    <script src="./vue.js"></script>
    <script>
        const app = new Vue({
            el: '#app',
            data: {
                cond: 1
            },
            methods: {
                one: function () {
                    this.cond = 1;
                },
                two: function () {
                    this.cond = 2;
                },
                three: function () {
                    this.cond = 3;
                },
            }
        });
        app.cond=4;

    </script>
</body>

</html>
